package bootstrap

import (
	"base"
	"proto/player"
	"proto/server/center"
	"proto/server/game"
	"proto/server/gate"
	"proto/server/login"
)

func init() {
	// client
	base.Processor.Register(new(proto_player.Request))
	base.Processor.Register(new(proto_player.Response))
	base.Processor.Register(new(proto_player.Login))
	base.Processor.Register(new(proto_player.OnLogin))
	base.Processor.Register(new(proto_player.Logout))
	base.Processor.Register(new(proto_player.OnLogout))

	// center server
	base.Processor.Register(new(proto_server_center.Login))
	base.Processor.Register(new(proto_server_center.Logout))
	base.Processor.Register(new(proto_server_center.OnLogout))
	base.Processor.Register(new(proto_server_center.Register))
	base.Processor.Register(new(proto_server_center.OnRegister))

	// game server
	base.Processor.Register(new(proto_server_game.Login))
	base.Processor.Register(new(proto_server_game.OnLogin))
	base.Processor.Register(new(proto_server_game.Logout))
	base.Processor.Register(new(proto_server_game.OnGateClose))
	base.Processor.Register(new(proto_server_game.OnGateRegister))

	// gate server
	base.Processor.Register(new(proto_server_gate.Request))
	base.Processor.Register(new(proto_server_gate.Response))
	base.Processor.Register(new(proto_server_gate.OnLogin))
	base.Processor.Register(new(proto_server_gate.OnLogout))
	base.Processor.Register(new(proto_server_gate.Register))

	// login server
	base.Processor.Register(new(proto_server_login.Login))
	base.Processor.Register(new(proto_server_login.OnLogin))
}
